home *** CD-ROM | disk | FTP | other *** search
/ EnigmA Amiga Run 1995 November / EnigmA AMIGA RUN 02 (1995)(G.R. Edizioni)(IT)[!][issue 1995-11][Skylink CD].iso / earcd / program / misc / tri14dev.lha / Triton / Developer / gcc / source / tr_getattribute.c < prev    next >
C/C++ Source or Header  |  1995-08-25  |  913b  |  30 lines

  1. /*
  2.  *  Triton - The object oriented GUI creation system for the Amiga
  3.  *  Written by Stefan Zeiger in 1993-1994
  4.  *
  5.  *  (c) 1993-1994 by Stefan Zeiger
  6.  *  You are hereby allowed to use this source or parts of it for
  7.  *  creating programs for AmigaOS which use the Triton GUI creation
  8.  *  system. All other rights reserved.
  9.  *
  10.  *  Triton linkable library code for GCC - (c) 1994 by Gunther Nikl
  11.  */
  12.  
  13. #include "triton.h"
  14.  
  15. extern struct Library *TritonBase;
  16.  
  17. ULONG TR_GetAttribute(struct TR_Project *project, ULONG id, ULONG attribute)
  18. {
  19.   register ULONG _res __asm("d0");
  20.   register struct Library *a6 __asm("a6") = TritonBase;
  21.   register struct TR_Project *a0 __asm("a0") = project;
  22.   register ULONG d0 __asm("d0") = id;
  23.   register ULONG d1 __asm("d1") = attribute;
  24.   __asm __volatile ("jsr a6@(-0x42)"
  25.   : "=r" (_res)
  26.   : "r" (a6), "r" (a0), "r" (d0), "r" (d1)
  27.   : "a0","a1","d0","d1", "memory");
  28.   return _res;
  29. }
  30.